<template>
    <z-table name="7spxcry7" :entitys="entitys" :before="before">
        <template #gstInclusiveSlot="data" >
            <gstInclusive :data="data"/>
        </template>
    </z-table>
</template>

<script>
import configs from './.lowcode/configs'
import gstInclusive from './blocks/gstInclusive.vue';

export default {
    name: 'p-7spxcry7',
    provide: {configs},
    components: {
        gstInclusive,
    },
    data() {
        return {
            entitys: {
                rate: {
                    type: "select"
                },
                category: {
                    depend: "mate_cate"
                }
            }
        }
    },
    methods: {
        before(formdata){
            const rate = formdata.rate;
            const taxExcluded = formdata.taxExcluded;
            formdata.gstInclusive = rate !== 0 && rate != null ? taxExcluded + taxExcluded * rate / 100 : taxExcluded
        }
    }
}
</script>
